package spacecraft;

import java.awt.Color;

import javax.sound.sampled.AudioSystem;

import markgame2d.engine.MarkGame;
import markgame2d.engine.MarkJFrame;

public class SpaceCraft extends MarkGame{

	private static SpaceCraft instance;
	
	public static final int WIDTH = 640;
	public static final int HEIGHT = 480;

	public BeginScreen beginScreen;
	public GameScreen gameScreen;
	public PauseScreen pauseScreen;
	public GameOverScreen gameOverScreen;
	
	private SpaceCraft(){
		super(WIDTH,HEIGHT, 30, Color.BLACK.brighter().brighter().brighter());
	}
	
	public void init(){
		beginScreen = new BeginScreen();
		gameScreen = new GameScreen();
		pauseScreen = new PauseScreen();
		gameOverScreen = new GameOverScreen();
		setScreen(beginScreen);
	}
	
	public static SpaceCraft getInstance() {
		if(instance == null){
			instance = new SpaceCraft();
		}
		return instance;
	}
	
	public static void main(String[] args) {

		SpaceCraft game = SpaceCraft.getInstance();
		game.init();
		
		MarkJFrame frame = new MarkJFrame(game, "Space Craft");
		frame.setVisible(true);

		game.start();

		
		
	}

}
